<template>
    <div style="padding:10px;">
        <a-button shape="round" size="small" type="primary"  @click="handleSubmit">生成图片</a-button>
    
    <div style="position:relative;background:red;">
        
        <div style="position: absolute;top:0px;left:0px;">
            <a-divider orientation="left">选择题</a-divider>
            <a-form :form="form" @submit="handleSubmit">
                
              
                    <a-form-item label="1.sasdasdasda">
                        <a-radio-group
                        :options="[{label:'第一选项',value:'A'},{label:'第二选项',value:'B'},{label:'第三选项',value:'C'}]" 
                        :disabled="false"
                        v-decorator="['itm1',{}]"/>
                        
                    </a-form-item>
                    
      

                
            </a-form>

           

            
        </div>
       
    </div>

    
    </div>
</template>

<script>

import {SysMixin} from '@/mixins/SysMixin'
import defaultSettings from '@/config/defaultSettings'
import vueEsign from 'vue-esign'

export default {
    name:'juanzi',
    components:{vueEsign},
    mixins:[SysMixin],
    data(){
        return{
            defaultSettings,
            lineWidth: 1,
            lineColor: '#000000',
            bgColor: '',
            resultImg: '',
            isCrop: false,
            signatureData:null,
            width:document.documentElement.clientWidth,
            height:document.documentElement.clientHeight,
            shiti:[
                {type:'1',list:[
                    {id:1,content:'sfsdafsafssafsafsd{}'}
                ]}
            ],
            form:{},

           
            
            
        }
    },
    created(){
         this.form=this.$form.createForm(this,{onValuesChange:this.valueChange}) 
    },

    mounted(){
        
    },
    methods:{
         handleSubmit () {
            this.form.validateFields((err, values) => {
                console.log(values)
            })
         
            // this.$refs.esign.generate().then(res => {
            //     this.resultImg = res
            //     console.log(this.resultImg)
            // }).catch(err => {
            //     alert(err) // 画布没有签字时会执行这里 'Not Signned'
            // })
        },
        valueChange(props, v){
            console.log(v)
        }

        
    }
    
}
</script>

<style scoped>

::v-deep .ant-input{
    border-left: none !important;
    border-top: none !important;
    border-right: none !important;
    box-shadow: none !important;
    background-color: #ffffff !important;
    color:rgba(0,0,0, 0.8) !important;
}
::v-deep .ant-input-number{
    border: none !important;
    box-shadow: none !important;
    background-color: #ffffff !important;
    color:rgba(0,0,0, 0.8) !important;
}
::v-deep .ant-select-selection{
    border: none !important;
    box-shadow: none !important;
    background-color: #ffffff !important;
    color:rgba(0,0,0, 0.8) !important;
}


</style>